/**
 *@title
 *@author huahuadavids
 *@date 2020/4/11
 */
import * as types from "../types"
const state1 = {
  number: 0
}

export default function (state=state1, action) {
  switch (action.type) {
    case types.INCREMENT:
      return {number: state.number + 1}
    case types.DECREMENT:
      return {number: state.number - 1}
    default:
     return state;
  }
}